<?=$this->load->view('public/v_html')?>
<title>淘宝客报表获取</title>
<link rel="stylesheet" href="<?=base_url ( 'css/reset.css' )?>" type="text/css" media="screen" />
<link rel="stylesheet" href="<?=base_url ( 'css/style.css' )?>" type="text/css" media="screen" />
<link rel="stylesheet" href="<?=base_url ( 'css/invalid.css' )?>" type="text/css" media="screen" />
<script type="text/javascript" src="<?=base_url('js/Calendar.js')?>"></script>
<script type="text/javascript" src="<?=base_url ( '/js/tbk.js' )?>"></script>
<script language="javascript">
var c = new Calendar("c");
	document.write(c);
</script>
</head>
<body>
<div id="main-content"> 
<div class="content-box">
	<div class="content-box-header">
		<h3><?=$this->_lang['r_title']?></h3>		
		<ul class="content-box-tabs">
			<li><a href="#tab1" class="default-tab"><?=$this->_lang['r_title']?></a></li>
		</ul>	
		<div class="clear"></div>	
	</div>
	<div class="content-box-content">
			<div class="tab-content default-tab" id="tab1">
			<?=@$data?>
			</div>
<form method="post" action="<?=base_url('index.php/creport/get_report') ?>">
日期:<input type="text" class="text-input small-input" id="date" name="date" onfocus="c.showMoreDay = false;c.show(this);" /><br/>
<input class="button" type="button" onclick="get_report();" value="提交"></input>
<p><?=@$error?></p>
</form>

</div>
</div>
</div>
<script type="text/javascript">
function get_report(){
	var date = $("#date").val();
	$.ajax({
		type:'POST',
		datatype:'json',
		url:"creport/get_report",
		data:{"date":date},
		success:function(res){
			eval("var ret = "+res);
			alert(ret.msg);
			window.location.reload();
		}
	});
}
</script>
</body>
</html>